From e879eaddc0c9a9dbca9d899a5ae378e3af0ec188 Mon Sep 17 00:00:00 2001 From: Jyrki Gadinger Date: Mon, 3 Mar 2025 17:53:56 +0100 Subject: [PATCH] gui: do not allow MainWindow to be resized previously macOS let you resize the activity window, resulting in strange visual artifacts... Signed-off-by: Jyrki Gadinger --- src/gui/tray/MainWindow.qml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/gui/tray/MainWindow.qml b/src/gui/tray/MainWindow.qml index cf13b90be..a30f4fc93 100644 --- a/src/gui/tray/MainWindow.qml +++ b/src/gui/tray/MainWindow.qml @@ -43,7 +43,16 @@ ApplicationWindow { readonly property int maxMenuHeight: Style.trayWindowHeight - Style.trayWindowHeaderHeight - 2 * Style.trayWindowBorderWidth - Component.onCompleted: Systray.forceWindowInit(trayWindow) + Component.onCompleted: { + Systray.forceWindowInit(trayWindow) + if (Systray.useNormalWindow) { + return; + } + + // do not allow this window to be resized when it's frameless + this.minimumWidth = this.maximumWidth = this.width + this.minimumHeight = this.maximumHeight = this.height + } // Close tray window when focus is lost (e.g. click somewhere else on the screen) onActiveChanged: { -- 2.30.2